﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using Automobile.service.BLL;
using Automobile.service.Model;

namespace Automobile.service.UI
{
    public partial class PurchaseInto : System.Web.UI.Page
    {
        PurchaseBLL bll = new PurchaseBLL();
        protected void Page_Load(object sender, EventArgs e)
        {
            if (!IsPostBack)
            {
                PurLoad();
            }
        }
        public void PurLoad()
        {
            this.Repeater1.DataSource = bll.PurIntoShow();//获取数据源
            this.Repeater1.DataBind();//绑定数据源
        }

        protected void Repeater1_ItemCommand(object source, RepeaterCommandEventArgs e)
        {
            string eName = e.CommandName;//获取当前要执行的命令名称
            string stuID = e.CommandArgument.ToString();//获取当前绑定的主键值
            switch (eName)
            {

                case "Into":
                    Response.Redirect("PurchaseIntoCheck.aspx?id=" + stuID);
                    break;
            }
        }
    }
}